package com.hong.spring.utils;

import com.alibaba.fastjson.JSONObject;
import com.qq.tars.server.core.AppContextEvent;
import com.qq.tars.server.core.AppContextListener;
import com.qq.tars.server.core.AppServantEvent;
import org.springframework.stereotype.Component;

@Component
public class AppStartListener implements AppContextListener {

    @Override
    public void appContextStarted(AppContextEvent event) {
        System.out.println("appContextStarted收到消息:"+ JSONObject.toJSONString(event));
    }

    @Override
    public void appServantStarted(AppServantEvent event) {
        System.out.println("appServantStarted收到消息:"+ JSONObject.toJSONString(event));
    }
}